Hello everyone,
This small code looks a bit like my “Day Trading Trend DAX H4”, although it is less efficient.
It takes positions on the CAC40, in M15 graphics, in the morning (hence its name), based on the current momentum, defined by a MACD on the last 14 hours (so the periods are multiplied by 56).
14 hours because it’s like the 08H to 22H day trading.
This code is profitable over the long term, logically.
| 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 | DEFPARAM CumulateOrders = False // Taille des positions n = 3 // Définition du MACD // Timeframe M15 p = 56 // 56*15 min = 14 HOURS, like 08H to 22H IndicMACD = MACD[12*p,26*p,9*p](close) // CONDITIONS ACHAT c1a = time = 093000 c2a = IndicMACD > IndicMACD[1] IF c1a and c2a THEN BUY n SHARES AT MARKET ENDIF // CONDITIONS VENTE c1v = time = 093000 c2v = IndicMACD < IndicMACD[1] IF c1v and c2v THEN SELLSHORT n SHARES AT MARKET ENDIF // SORTIE c1sa = time = 214500 IF c1sa THEN SELL AT MARKET EXITSHORT AT MARKET ENDIF // STOP LOSS & TAKE PROFIT SET STOP %LOSS 1 | 
Share this
No information on this site is investment advice or a solicitation to buy or sell any financial instrument. Past performance is not indicative of future results. Trading may expose you to risk of loss greater than your deposits and is only suitable for experienced investors who have sufficient financial means to bear such risk.
ProRealTime ITF files and other attachments : Filename : download the ITF files
									Filename : download the ITF filesPRC is also on YouTube, subscribe to our channel for exclusive content and tutorials
 
								
							
 
									 
									 
										 
										 
										 
										 
										 
										 
										 
								
 
								 
									 
								 
								 
								
 
								 
								
 
								 
									 
								
 
										 
								 
									
 
										 
										 
								 
										
 
								
 
								 
									
 
								 
									 
										 
									 
									 
										 
								 
									 
									 
		 
		 
		
Thank you,
I’ll try to mix this code with the “Breakout strategy” to see if they can improve each other.
Yes, nice idea.
I tried some backtests with “9:30 MACD” with “Breakout strategy” but results are much better with MACD value at the time of the candle cross over the target price.
Hello, can you send us your code ?